Call the RevisionInsertComplete from RevisionStore for now, so extensions
that still rely on this hook don't break when more code uses RevisionStore
instead of Revision.
This specifically avoid breaking EventBus and Translate when If610c68f491
is merged.
Change-Id: I3356c8250d7934e0089d4627fdebddf7983f194f
// Avoid PHP 7.1 warning of passing $this by reference
$revision = $this;
- // TODO: hard-deprecate in 1.32 (or even 1.31?)
- Hooks::run( 'RevisionInsertComplete', [ &$revision, null, null ] );
return $rec->getId();
}
use Psr\Log\LoggerInterface;
use Psr\Log\NullLogger;
use RecentChange;
+use Revision;
use stdClass;
use Title;
use User;
Hooks::run( 'RevisionRecordInserted', [ $rev ] );
+ // TODO: deprecate in 1.32!
+ $legacyRevision = new Revision( $rev );
+ Hooks::run( 'RevisionInsertComplete', [ &$legacyRevision, null, null ] );
+
return $rev;
}